import req from './request.js'


export const createCache = (port) => {
    return req.post('/api/clearCache', {port})
}

export const restartService = (port, password) => {
    return req.post('/api/restartService', {port, password})
}

export const closeGateway = (password) => {
    return req.post('/api/close', {password})
}

export const refreshMonitor = () => {
    return req.post('/api/refreshMonitor', {})
}

export const consoleInfo = () => {
    return req.get('/api/console')
}

export const terminalConsole = () => {
    return req.get('/api/terminalConsole')
}
